package com.zhangshujie.ShoppingSystem;

import java.io.Serializable;

class Product implements Serializable {
    String id;
    String name;
    String manufacturer;
    String productionDate;
    String model;
    double purchasePrice;
    double retailPrice;
    int quantity;

    public Product(String id, String name, String manufacturer, String model, String productionDate, double purchasePrice, double retailPrice, int quantity) {
        this.id = id;
        this.name = name;
        this.manufacturer = manufacturer;
        this.model = model;
        this.productionDate = productionDate;
        this.purchasePrice = purchasePrice;
        this.retailPrice = retailPrice;
        this.quantity = quantity;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getManufacturer() {
        return manufacturer;
    }

    public void setManufacturer(String manufacturer) {
        this.manufacturer = manufacturer;
    }

    public String getProductionDate() {
        return productionDate;
    }

    public void setProductionDate(String productionDate) {
        this.productionDate = productionDate;
    }

    public String getModel() {
        return model;
    }

    public void setModel(String model) {
        this.model = model;
    }

    public double getPurchasePrice() {
        return purchasePrice;
    }

    public void setPurchasePrice(double purchasePrice) {
        this.purchasePrice = purchasePrice;
    }

    public double getRetailPrice() {
        return retailPrice;
    }

    public void setRetailPrice(double retailPrice) {
        this.retailPrice = retailPrice;
    }

    public int getQuantity() {
        return quantity;
    }

    public void setQuantity(int quantity) {
        this.quantity = quantity;
    }

    @Override
    public String toString() {
        return STR."Product{id=\{id}, name='\{name}\{'\''}, manufacturer='\{manufacturer}\{'\''}, productionDate=\{productionDate}, model='\{model}\{'\''}, purchasePrice=\{purchasePrice}, retailPrice=\{retailPrice}, quantity=\{quantity}\{'}'}";
    }
}
